<?php
declare (strict_types = 1);

namespace app\api\model\v1;

use think\Model;

/**
 * @mixin \think\Model
 */
class ProjectDetail extends AppModel
{
    //关联关系
    public function gatherFile(){
        return $this->hasMany(GatherFile::class,'project_detail_id');
    }
    //已审核统计
    public function gatherFileYet(){
        return $this->hasMany(GatherFile::class,'project_detail_id');
    }
    //未审核统计
    public function gatherFileNot(){
        return $this->hasMany(GatherFile::class,'project_detail_id');
    }

    public function project(){
        return $this->belongsTo(Project::class,'project_id');
    }

    public function projectType(){
        return $this->belongsTo(ProjectType::class,'project_type_id');
    }

    public function projectSecond(){
        return $this->belongsTo(ProjectSecondLevel::class,'project_second_level_id');
    }
}
